Send a Command/Query to an Instrument/Device through the VISA interface (GPIB / TCP)
#include <Visa.au3>
_viFindGpib(ByRef $a_descriptor_list, ByRef $a_idn_list, $f_show_search_results = 0)
Parameters
$a_descriptor_list (ByRef) | RETURNS an array of the VISA resource descriptors of the instruments that were found in the GPIB bus (see the Remarks of the _viExecCommand for more info) |
$a_idn_list (ByRef) | RETURNS an array of the IDNs (i.e names) of the instruments that were found in the GPIB bus |
$f_show_search_results | Optional: If 1 a message box showing the results of the search will be shown. The default is 0, which means that the results are not shown |
Return Value
Success: | The number of instruments found (0 or more) |
Failure: | Returns a NEGATIVE value and SETS @error to 1 |
Remarks
As for all the VISA functions the VISA libraries must be installed (you can check whether visa32.dll is in {WINDOWS}\system32) and a GPIB card (such as a National Instruments NI PCI-GPIB card or an Agilent 82350B PCI High-Performance GPIB card) must be installed
Related
_viExecCommand, _viOpen, _viClose, _viGTL
Example
; This example performs a search on the GPIB bus and shows the results in a MsgBox
#include <Visa.au3>
Dim $a_descriptor_list[1], $a_idn_list[1]
_viFindGpib($a_descriptor_list, $a_idn_list, 1)